package com.leyou.auth.controller;

import com.leyou.auth.dto.AliOssSignatureDTO;
import com.leyou.auth.service.AliAuthService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Author: SGS
 * @Date : 2020/11/16 16:55
 * @Version :
 */
@RestController
@RequestMapping("ali")
public class AliAuthController {

    @Autowired
    private AliAuthService aliAuthService;

    @GetMapping("/oss/signature")
    public ResponseEntity<AliOssSignatureDTO> getAliOssSignature(){
    aliAuthService.getAliOssSignature();
    return ResponseEntity.ok(aliAuthService.getAliOssSignature());
    }
}
